import VueRouter from 'vue-router';
import { Header } from 'mint-ui';
import HomeContainer from './components/tabbar/HomeContainer.vue'
import MemberContainer from './components/tabbar/MemberContainer.vue'
import ShopcarContainer from './components/tabbar/ShopcarContainer.vue'
import SearchContainer from './components/tabbar/SearchContainer.vue'
import newslist from './components/news/newslist.vue'
import newsinfo from './components/news/newsinfo.vue'
import ProductList from './components/product_box/ProductList.vue'
import productinfo from './components/product_box/ProductInfo.vue'
const router = new VueRouter({
    routes:[
        { path:"/",redirect:'/home' },
        { path:'/home',component:HomeContainer},
        { path:'/home/newslist',component:newslist },
        { path:'/member',component:MemberContainer },
        { path:'/shopcar',component:ShopcarContainer },
        { path:'/search',component:SearchContainer },
        { path:'/home/newsinfo/:id',component:newsinfo },
        { path:'/home/productlist',component:ProductList },
        { path:'/home/productinfo/:id',component:productinfo }
    ],
    linkExactActiveClass:'mui-active'
})
//把路由对象暴露出去
export default router;